package com.bsj.travel.openapi.service;

import com.bsj.travel.def.common.DTO.web.openApi.device.DeviceOpenApiDTO;
import com.bsj.travel.def.common.DTO.web.openApi.device.DeviceOpenApiMsgReportDTO;
import com.bsj.travel.def.common.DTO.web.openApi.device.DeviceOpenApiParamDTO;
import com.bsj.travel.def.common.VO.device.DeviceCorrelationInfoVO;
import com.bsj.travel.def.global.JsonResult;

import java.util.List;

/**
 * @author LiJiaXin
 * @version 1.0.0
 * @description DeviceOpenApiService
 * @time 2024/4/7 14:43
 */
public interface DeviceOpenApiService {

    /**
     * 添加设备
     *
     * @param deviceOpenApiDTO
     * @return com.bsj.travel.def.global.JsonResult
     * @author ljx
     * @time 2024/4/7 14:47
     */
    JsonResult addDevice(DeviceOpenApiDTO deviceOpenApiDTO);

    /**
     * 批量添加设备
     *
     * @param deviceOpenApiParamDTO
     * @return com.bsj.travel.def.global.JsonResult
     * @author ljx
     * @time 2024/4/8 11:16
     */
    JsonResult batchAddDevice(DeviceOpenApiParamDTO deviceOpenApiParamDTO);

    /**
     * 删除设备
     *
     * @param deviceOpenApiParamDTO
     * @return com.bsj.travel.def.global.JsonResult
     * @author ljx
     * @time 2024/4/8 11:48
     */
    JsonResult deleteDevice(DeviceOpenApiParamDTO deviceOpenApiParamDTO);

    /**
     * 获取设备详情
     *
     * @param productKey
     * @param deviceName
     * @return com.bsj.travel.def.global.JsonResult
     * @author ljx
     * @time 2024/4/8 13:57
     */
    DeviceCorrelationInfoVO getByDeviceName(String productKey, String deviceName);

    /**
     * 批量获取设备详情
     *
     * @param productKey
     * @param deviceNames
     * @return com.bsj.travel.def.global.JsonResult
     * @author ljx
     * @time 2024/4/8 14:28
     */
    List<DeviceCorrelationInfoVO> batchQueryDeviceDetail(String productKey, List<String> deviceNames);

    /**
     * 消息发布
     *
     * @param deviceOpenApiMsgReportDTO
     * @return com.bsj.travel.def.global.JsonResult
     * @author ljx
     * @time 2024/4/8 15:06
     */
    JsonResult pub(DeviceOpenApiMsgReportDTO deviceOpenApiMsgReportDTO);
}
